﻿@model IEnumerable<EventSys.BussinesEntities.Carrera>

@{
    ViewBag.Title = "Index";
    Layout = "~/Views/Shared/_Layout.cshtml";
}

<h2>BUSCAR CERRERA</h2>

<p>
    @Html.ActionLink("Nuevo", "Create")
</p>

@using (Html.BeginForm())
{
    <fieldset>
        <legend></legend><b>Ingrese Carrera:</b> 
        <input type="search" name="criterio" value="" placeholder="Ingrese Descripcion"/>
        <input type="submit" name="buscar" value="Buscar" class="k-button"/>
    </fieldset>
}


<div class="CSSTableGenerator">
<table style="width:500px">


    <tr>
        <th>
            @Html.DisplayNameFor(model => model.idCarrera)
        </th>
        <th>
            @Html.DisplayNameFor(model => model.Carrera1)
        </th>
        <th>
            @Html.DisplayNameFor(model => model.idFacultad)
        </th>
        <th></th>
    </tr>

@foreach (var item in Model) {
    <tr>
        <td>
            @Html.DisplayFor(modelItem => item.idCarrera)
        </td>
        <td>
            @Html.DisplayFor(modelItem => item.Carrera1)
        </td>
        <td>
            @*@Html.DisplayFor(modelItem => item.idFacultad)*@
            @Html.DisplayFor(modelItem => item.Facultad.Facultad1)
        </td>
        <td>
            @Html.ActionLink("Editar", "Edit", new { id=item.idCarrera  }) 
        </td>
    </tr>
}

</table>
